A Concurrent Copying Garbage Collector for Languages that Distinguish ( Im ) mutable
نویسنده
چکیده
This paper describes the design and implementation of a concurrent compacting garbage collector for languages that distinguish mutable data from immutable data (e.g., ML) as well as for languages that manipulate only immutable data (e.g., pure functional languages such as Haskell). The collector runs on shared-memory parallel computers and requires minimal mutator/collector synchronization. No special hardware or operating system support is required. Our concurrent collector derives from sequential semi-space copying collectors. The collector requires that a heap object includes a forwarding pointer in addition to its data elds. An access to an immutable object can be satis ed either by the original or the forwarded copy of the object. A mutable object is always accessed through the forwarded copy, if one exists. Measurements of this collector in a Standard ML compiler on a shared-memory computer indicate that it eliminates perceptible garbage-collection pauses by reclaiming storage in parallel with the computation proper. All observed pause times are less than 20 milliseconds. We describe extensions for the concurrent collection of multiple mutator threads and re nements to our design that can improve its e ciency. This work was supported in part by the National Science Foundation under grant CCR-9101035. L. Huelsbergen is supported by an ARPA fellowship in parallel processing. Authors's address: Department of Computer Sciences, 1210 West Dayton Street, Madison, Wisconsin 53706. Email: florenz,[email protected]
منابع مشابه
Mostly-Copying Collection: A Viable Alternative to Conservative Mark-Sweep
Many high-level language compilers generate C code and then invoke a C compiler to do code generation, register allocation, stack management, and low-level optimization. To date, most of these compilers link the resulting code against a conservative mark-sweep garbage collector in order to reclaim unused memory. We introduce a new collector, MCC, based on mostly-copying collection, and characte...
متن کاملUsing Multiple Servers in Concurrent
Object-oriented programming languages are being widely adopted as one of the most powerful languages due their flexibility and reusability. However, these languages suffer from memory mismanagement that could be critical especially in real-time and embedded systems. Automatic memory management through garbage collector handles this problem. Concurrent garbage collection based on sporadic or def...
متن کاملGarbage Collection Alternatives for Icon
Copying garbage collectors are becoming the collectors of choice for very high-level languages and for functional and object-oriented languages. Copying collectors are particularly efficient for large storage regions because their execution time is proportional only to the amount of accessible data, and they identify and compact this data in one pass. In contrast, mark-and-sweep collectors exec...
متن کاملGenerational Garbage Collection for Lazy Functional Languages without Temporary Space Leaks
Generational garbage collection is an established method for creating eecient garbage collectors. Even a simple implementation where all nodes that survive one garbage collection are tenured, i.e., moved to an old generation, works well in strict languages. In a lazy language, however, such an implementation can create severe temporary space leaks. The temporary space leaks appear in programs t...
متن کاملGenerational Garbage Collection without Temporary Space Leaks for Lazy Functional Languages
Generational garbage collection is an established method for creating eecient garbage collectors. Even a simple implementation where all nodes that survive one garbage collection are tenured, i.e., moved to an old generation , works well in strict languages. In lazy languages, however, such an implementation can create severe temporary space leaks. The temporary space leaks appear in programs t...
متن کامل